package com.zx.framework.plat.dept.po;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.Table;
import javax.validation.constraints.NotNull;

import org.hibernate.validator.constraints.Length;
import org.hibernate.validator.constraints.NotEmpty;

/**
 * Dept entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "s_dept")
public class Dept implements java.io.Serializable {

	// Fields
	private String id;
	private String companyId;
	private String owner;
	@NotEmpty(message="部门名称不能为空！")
	private String name;
	private String labels;
	private String layer;
	private String orders;
	private String type;
	private String otherId;
	@NotNull(message="部门状态不能为空！")
	private Integer status;
	private String remark;

	// Constructors

	/** default constructor */
	public Dept() {
	}

	/** minimal constructor */
	public Dept(String id, String name, String layer, String orders,
			Integer status) {
		this.id = id;
		this.name = name;
		this.layer = layer;
		this.orders = orders;
		this.status = status;
	}

	/** full constructor */
	public Dept(String id, String companyId, String owner, String name,
			String labels, String layer, String orders, String type,
			String otherId, Integer status, String remark) {
		this.id = id;
		this.companyId = companyId;
		this.owner = owner;
		this.name = name;
		this.labels = labels;
		this.layer = layer;
		this.orders = orders;
		this.type = type;
		this.otherId = otherId;
		this.status = status;
		this.remark = remark;
	}

	// Property accessors
	@Id
	@Column(name = "ID", unique = true, nullable = false, length = 64)
	public String getId() {
		return this.id;
	}

	public void setId(String id) {
		this.id = id;
	}

	@Column(name = "COMPANYID", length = 64)
	public String getCompanyId() {
		return this.companyId;
	}

	public void setCompanyId(String companyId) {
		this.companyId = companyId;
	}

	@Column(name = "OWNER", length = 64)
	public String getOwner() {
		return this.owner;
	}

	public void setOwner(String owner) {
		this.owner = owner;
	}

	@Column(name = "NAME", nullable = false, length = 64)
	public String getName() {
		return this.name;
	}

	public void setName(String name) {
		this.name = name;
	}

	@Column(name = "LABELS", length = 1024)
	public String getLabels() {
		return this.labels;
	}

	public void setLabels(String labels) {
		this.labels = labels;
	}

	@Column(name = "LAYER", nullable = false, length = 256)
	public String getLayer() {
		return this.layer;
	}

	public void setLayer(String layer) {
		this.layer = layer;
	}

	@Column(name = "ORDERS", nullable = false, length = 256)
	public String getOrders() {
		return this.orders;
	}

	public void setOrders(String orders) {
		this.orders = orders;
	}

	@Column(name = "TYPE", length = 64)
	public String getType() {
		return this.type;
	}

	public void setType(String type) {
		this.type = type;
	}

	@Column(name = "OTHERID", length = 64)
	public String getOtherId() {
		return this.otherId;
	}

	public void setOtherId(String otherId) {
		this.otherId = otherId;
	}

	@Column(name = "STATUS", nullable = false, precision = 1, scale = 0)
	public Integer getStatus() {
		return this.status;
	}

	public void setStatus(Integer status) {
		this.status = status;
	}

	@Column(name = "REMARK", length = 100)
	public String getRemark() {
		return this.remark;
	}

	public void setRemark(String remark) {
		this.remark = remark;
	}

}